<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <script>
        /* 字符串：引号。
        1.特殊字符， 用转义符。
        2.length 获取字符串的长度(有多少个字符)
        3.+ 可以进行字符串的拼接
        4.字符串拼接其它字符串类型后还是字符串
        5.字符串和变量拼接：引引加加
        */
       let address ='海\'岛\n吃鸡地图';
       console.log(address);


       let hero="无极剑圣";
       let supstar="周星驰";
       console.log("hero的长度是: " + hero.length);
       console.log("supstar的长度是: " + supstar.length);


       let subject ='ddz';
       let subject1 ='zxc';
       let result = 'ddz' + 'zxc';
       console.log(result);
       console.log(subject + subject1);


       let star='周星驰';
       star =star +true;
       console.log(typeof star);//字符串拼接其他字符串类型后还是字符串



       let game ='穿越火线';
       console.log("王者"+game+"吃鸡");//字符串和变量拼接：引引加加
       </script>
</body>

</html>